From: Colin Walters Date: Mon, 15 Dec 2014 18:59:46 +0000 (-0500) Subject: repo: (cleanup) Use _is_system() rather than inlining it X-Git-Tag: archive/raspbian/2022.1-3+rpi1~1^2~1021 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=8067e977a7280f3033406b208569464ffb630e92;p=ostree.git repo: (cleanup) Use _is_system() rather than inlining it No reason to duplicate the code. --- diff --git a/src/libostree/ostree-repo.c b/src/libostree/ostree-repo.c index 4f2fc9aa..b627046b 100644 --- a/src/libostree/ostree-repo.c +++ b/src/libostree/ostree-repo.c @@ -1236,15 +1236,11 @@ ostree_repo_open (OstreeRepo *self, ostree_repo_set_disable_fsync (self, TRUE); } - { - gs_unref_object GFile *default_repo_path = get_default_repo_path (); - - if (g_file_equal (self->repodir, default_repo_path)) - { - if (!append_remotes_d (self, cancellable, error)) - goto out; - } - } + if (ostree_repo_is_system (self)) + { + if (!append_remotes_d (self, cancellable, error)) + goto out; + } if (!gs_file_open_dir_fd (self->tmp_dir, &self->tmp_dir_fd, cancellable, error)) goto out;